package com.zzyl.job;

import com.zzyl.mapper.ReservationMapper;
import lombok.RequiredArgsConstructor;
import com.xxl.job.core.handler.annotation.XxlJob;

import org.springframework.stereotype.Component;

import java.time.LocalDateTime;

@Component
@RequiredArgsConstructor
public class MyTask {
    private final ReservationMapper reservationMapper;
    @XxlJob("UpdateStatusHandler")
    public void task() {
        reservationMapper.updateReservationStatus(LocalDateTime.now());
    }


}
